package com.shardingsphere.service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.shardingsphere.entity.User;
import com.shardingsphere.mapper.UserMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author biao.yang
 * @Description:
 * @date 2025/2/18 18:23
 */
@Service
public class UserService extends ServiceImpl<UserMapper, User> {

    @Autowired
    private UserMapper userMapper;

    public void selectUser(){
        userMapper.selectUser();
    }

    public void insertUser(){
        User user = new User();
        user.setUsername("admin");
        user.setEmail("admin@shardingsphere.com");
        userMapper.insert(user);
    }
}
